package PlaneTest;

import java.awt.*;

//爆炸类
public class ExPloder {
    //位置
    double x,y;

    int count;

    static Image[] imgs = new Image[16];

    static {

        for (int i = 0; i < 16; i++) {
            imgs[i] = GameUtil.ImageGame("images/peng/"+(i+1)+".gif");
            //解决图片多次调用，加不加都行
//            imgs[i].getWidth(null);
        }
    }

    public void drawMyself(Graphics g){
        if (count < 16){
            g.drawImage(imgs[count],(int)x,(int)y,null);
            count++;
        }



    }
    public ExPloder(){

    }

    public ExPloder(double x, double y) {
        this.x = x;
        this.y = y;
    }
}
